X
You can use the object.keys(name of object) method to see if the object has any properties in it. If it does, it will return an array with the names of the properties in it. If the object doesn't it will return an empty array.
You can use Object.keys(name of object).length too. If the object has something in it will return a positive number, which is a truthy value. If not it will return 0, a falsey value.
obj.hasOwnProperty(string) test to see if the object has a specific property in it. It returns true if it does, false if it doesn't. The string is the name of the property you want to check for. The obj is the particular object you want to check.